﻿namespace HRM.CORE
{
    using DevExpress.Utils;
    using DevExpress.XtraEditors;
    using DevExpress.XtraEditors.Controls;
    using DevExpress.XtraEditors.Mask;
    using DevExpress.XtraGrid.Columns;
    using DevExpress.XtraGrid.Views.Grid;
    using DevExpress.XtraLayout;
    using DevExpress.XtraLayout.Utils;
    using Common.Class; using APP.HELPER.Utils.Language; using Security.Security; using Dictionary.ERP;
    using HRM.CORE;
    using System; using Extra.ERP;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Runtime.CompilerServices;
    using System.Windows.Forms; using Common;

    public class xfmC68aHDAdd : XtraForm
    {
        private SimpleButton btClose;
        private SimpleButton btIncrease;
        private SimpleButton btNext;
        private CalcEdit calHomeAbsent;
        private CalcEdit calMoney;
        private CalcEdit calProgressAbsent;
        private CalcEdit calPublicAbsent;
        private ComboBoxEdit cboCondition;
        private GridColumn colPayInsuranceTableListName;
        private IContainer components;
        private DataTable dt_Employee;
        private DateEdit dtFromDate;
        private DateEdit dtToDate;
        private EmptySpaceItem emptySpaceItem1;
        private GridLookUpEdit glkPayInsuranceTableList;
        private GridView gridLookUpEdit1View;
        private GroupControl groupControl1;
        private DevExpress.Utils.ImageCollection imageCollection1;
        private LayoutControl layoutControl1;
        private LayoutControlGroup layoutControlGroup1;
        private LayoutControlItem layoutControlItem1;
        private LayoutControlItem layoutControlItem10;
        private LayoutControlItem layoutControlItem2;
        private LayoutControlItem layoutControlItem3;
        private LayoutControlItem layoutControlItem4;
        private LayoutControlItem layoutControlItem5;
        private LayoutControlItem layoutControlItem6;
        private LayoutControlItem layoutControlItem7;
        private LayoutControlItem layoutControlItem8;
        private LayoutControlItem layoutControlItem9;
        private Guid m_C68aHD;
        private string m_Condition;
        private int m_Count;
        private string m_Description;
        private string m_EmployeeCode;
        private string m_EmployeeName;
        private decimal m_Money;
        private Guid m_PayInsuranceTableListID;
        private int m_ProgressAbsent;
        private decimal m_Salary;
        private string m_SocialInsuranceCode;
        private int m_TermAbsent;
        private string m_Time;
        private int m_Type;
        private MemoEdit txtDescription;
        private TextEdit txtTime;

        public event CreatedEventHander Created;

        public xfmC68aHDAdd()
        {
            this.components = null;
            this.m_Count = 0;
            this.InitializeComponent();
            this.Init();
        }

        public xfmC68aHDAdd(DataTable Employee)
        {
            this.components = null;
            this.m_Count = 0;
            this.InitializeComponent();
            this.dt_Employee = Employee;
            this.m_Count = this.dt_Employee.Rows.Count - 1;
            this.Init();
        }

        private void btClose_Click(object sender, EventArgs e)
        {
            base.Close();
        }

        private void btIncrease_Click(object sender, EventArgs e)
        {
            if (this.glkPayInsuranceTableList.EditValue == null)
            {
                XtraMessageBox.Show("Vui l\x00f2ng chọn đợt b\x00e1o c\x00e1o cần ph\x00e1t sinh!", "Th\x00f4ng B\x00e1o", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
            }
            else
            {
                HRM_PAYINSURANCE_C68AHD hrm_payinsurance_cahd = new HRM_PAYINSURANCE_C68AHD();
                if (this.InitClass().Insert() == "OK")
                {
                    if (this.btNext.Enabled)
                    {
                        this.SetValue(this.m_Count);
                    }
                    else
                    {
                        XtraMessageBox.Show("Dữ liệu ph\x00e1t sinh đ\x00e3 được lưu lại!", "Th\x00f4ng B\x00e1o", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        this.RaiseCreatedEventHander();
                        base.Close();
                    }
                }
                else
                {
                    XtraMessageBox.Show("Dữ liệu kh\x00f4ng được lưu!\nVui l\x00f2ng kiểm tra lại!", "Lỗi", MessageBoxButtons.OK, MessageBoxIcon.Hand);
                }
            }
        }

        private void btNext_Click(object sender, EventArgs e)
        {
            this.SetValue(this.m_Count);
        }

        protected override void Dispose(bool disposing)
        {
            if (disposing && (this.components != null))
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }

        private void glk_ButtonClick(object sender, ButtonPressedEventArgs e)
        {
            xfmPayInsuranceAdd.AddedEventHander hander = null;
            if (e.Button.Kind == ButtonPredefines.Glyph)
            {
                GridLookUpEdit edit = sender as GridLookUpEdit;
                string name = edit.Name;
                if ((name != null) && (name == "glkPayInsuranceTableList"))
                {
                    xfmPayInsuranceAdd add = new xfmPayInsuranceAdd(Actions.Add);
                    if (hander == null)
                    {
                        hander = (s, i) => new HRM_PAYINSURANCE_TABLELIST().AddGridLookupEdit(this.glkPayInsuranceTableList);
                    }
                    add.Added += hander;
                    add.ShowDialog();
                }
            }
        }

        private void Init()
        {
            this.InitData();
            this.SetValue(this.m_Count);
        }

        private HRM_PAYINSURANCE_C68AHD InitClass()
        {
            return new HRM_PAYINSURANCE_C68AHD { C68aHDID = Guid.NewGuid(), PayInsuranceTableListID = new Guid(this.glkPayInsuranceTableList.EditValue.ToString()), EmployeeCode = this.m_EmployeeCode, EmployeeName = this.m_EmployeeName, SocialInsuranceCode = this.m_SocialInsuranceCode, Condition = this.cboCondition.Text, Time = this.txtTime.Text, ProgressAbsent = Convert.ToInt32(this.calProgressAbsent.EditValue.ToString()), PublicAbsent = Convert.ToInt32(this.calPublicAbsent.EditValue.ToString()), HomeAbsent = Convert.ToInt32(this.calHomeAbsent.EditValue.ToString()), Money = Convert.ToDecimal(this.calMoney.EditValue.ToString()), FromDate = System.DateTime.Parse(this.dtFromDate.EditValue.ToString()), ToDate = System.DateTime.Parse(this.dtToDate.EditValue.ToString()), Description = this.txtDescription.Text };
        }

        private void InitData()
        {
            this.dtFromDate.DateTime = System.DateTime.Now;
            this.dtToDate.DateTime = System.DateTime.Now;
            new HRM_PAYINSURANCE_TABLELIST().AddGridLookupEdit(this.glkPayInsuranceTableList);
        }

        private void InitializeComponent()
        {
            this.components = new Container();
            ComponentResourceManager manager = new ComponentResourceManager(typeof(xfmC68aHDAdd));
            SerializableAppearanceObject appearance = new SerializableAppearanceObject();
            this.groupControl1 = new GroupControl();
            this.layoutControl1 = new LayoutControl();
            this.dtToDate = new DateEdit();
            this.dtFromDate = new DateEdit();
            this.cboCondition = new ComboBoxEdit();
            this.calHomeAbsent = new CalcEdit();
            this.glkPayInsuranceTableList = new GridLookUpEdit();
            this.gridLookUpEdit1View = new GridView();
            this.colPayInsuranceTableListName = new GridColumn();
            this.calMoney = new CalcEdit();
            this.txtDescription = new MemoEdit();
            this.calProgressAbsent = new CalcEdit();
            this.calPublicAbsent = new CalcEdit();
            this.txtTime = new TextEdit();
            this.layoutControlGroup1 = new LayoutControlGroup();
            this.layoutControlItem5 = new LayoutControlItem();
            this.layoutControlItem8 = new LayoutControlItem();
            this.layoutControlItem9 = new LayoutControlItem();
            this.emptySpaceItem1 = new EmptySpaceItem();
            this.layoutControlItem4 = new LayoutControlItem();
            this.layoutControlItem2 = new LayoutControlItem();
            this.layoutControlItem6 = new LayoutControlItem();
            this.layoutControlItem3 = new LayoutControlItem();
            this.layoutControlItem7 = new LayoutControlItem();
            this.layoutControlItem1 = new LayoutControlItem();
            this.layoutControlItem10 = new LayoutControlItem();
            this.btIncrease = new SimpleButton();
            this.imageCollection1 = new DevExpress.Utils.ImageCollection(this.components);
            this.btClose = new SimpleButton();
            this.btNext = new SimpleButton();
            this.groupControl1.BeginInit();
            this.groupControl1.SuspendLayout();
            this.layoutControl1.BeginInit();
            this.layoutControl1.SuspendLayout();
            this.dtToDate.Properties.VistaTimeProperties.BeginInit();
            this.dtToDate.Properties.BeginInit();
            this.dtFromDate.Properties.VistaTimeProperties.BeginInit();
            this.dtFromDate.Properties.BeginInit();
            this.cboCondition.Properties.BeginInit();
            this.calHomeAbsent.Properties.BeginInit();
            this.glkPayInsuranceTableList.Properties.BeginInit();
            this.gridLookUpEdit1View.BeginInit();
            this.calMoney.Properties.BeginInit();
            this.txtDescription.Properties.BeginInit();
            this.calProgressAbsent.Properties.BeginInit();
            this.calPublicAbsent.Properties.BeginInit();
            this.txtTime.Properties.BeginInit();
            this.layoutControlGroup1.BeginInit();
            this.layoutControlItem5.BeginInit();
            this.layoutControlItem8.BeginInit();
            this.layoutControlItem9.BeginInit();
            this.emptySpaceItem1.BeginInit();
            this.layoutControlItem4.BeginInit();
            this.layoutControlItem2.BeginInit();
            this.layoutControlItem6.BeginInit();
            this.layoutControlItem3.BeginInit();
            this.layoutControlItem7.BeginInit();
            this.layoutControlItem1.BeginInit();
            this.layoutControlItem10.BeginInit();
            this.imageCollection1.BeginInit();
            base.SuspendLayout();
            this.groupControl1.Controls.Add(this.layoutControl1);
            this.groupControl1.Dock = DockStyle.Top;
            this.groupControl1.Location = new Point(0, 0);
            this.groupControl1.Name = "groupControl1";
            this.groupControl1.ShowCaption = false;
            this.groupControl1.Size = new Size(0x1f3, 0x13b);
            this.groupControl1.TabIndex = 0;
            this.groupControl1.Text = "Th\x00f4ng tin";
            this.layoutControl1.Controls.Add(this.dtToDate);
            this.layoutControl1.Controls.Add(this.dtFromDate);
            this.layoutControl1.Controls.Add(this.cboCondition);
            this.layoutControl1.Controls.Add(this.calHomeAbsent);
            this.layoutControl1.Controls.Add(this.glkPayInsuranceTableList);
            this.layoutControl1.Controls.Add(this.calMoney);
            this.layoutControl1.Controls.Add(this.txtDescription);
            this.layoutControl1.Controls.Add(this.calProgressAbsent);
            this.layoutControl1.Controls.Add(this.calPublicAbsent);
            this.layoutControl1.Controls.Add(this.txtTime);
            this.layoutControl1.Dock = DockStyle.Fill;
            this.layoutControl1.Location = new Point(2, 2);
            this.layoutControl1.Name = "layoutControl1";
            this.layoutControl1.Root = this.layoutControlGroup1;
            this.layoutControl1.Size = new Size(0x1ef, 0x137);
            this.layoutControl1.TabIndex = 0;
            this.layoutControl1.Text = "layoutControl1";
            this.dtToDate.EditValue = null;
            this.dtToDate.Location = new Point(0x13d, 0x8f);
            this.dtToDate.Name = "dtToDate";
            this.dtToDate.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.dtToDate.Properties.VistaTimeProperties.Buttons.AddRange(new EditorButton[] { new EditorButton() });
            this.dtToDate.Size = new Size(0xab, 20);
            this.dtToDate.StyleController = this.layoutControl1;
            this.dtToDate.TabIndex = 7;
            this.dtFromDate.EditValue = null;
            this.dtFromDate.Location = new Point(0x72, 0x8f);
            this.dtFromDate.Name = "dtFromDate";
            this.dtFromDate.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.dtFromDate.Properties.VistaTimeProperties.Buttons.AddRange(new EditorButton[] { new EditorButton() });
            this.dtFromDate.Size = new Size(0x8f, 20);
            this.dtFromDate.StyleController = this.layoutControl1;
            this.dtFromDate.TabIndex = 6;
            this.cboCondition.EditValue = "Ốm";
            this.cboCondition.Location = new Point(0x72, 7);
            this.cboCondition.Name = "cboCondition";
            this.cboCondition.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.cboCondition.Properties.Items.AddRange(new object[] { "Ốm", "Ốm phẩu thuật", "Ốm d\x00e0i ng\x00e0y" });
            this.cboCondition.Size = new Size(0x176, 20);
            this.cboCondition.StyleController = this.layoutControl1;
            this.cboCondition.TabIndex = 0;
            int[] bits = new int[4];
            this.calHomeAbsent.EditValue = new decimal(bits);
            this.calHomeAbsent.Location = new Point(0x153, 0x59);
            this.calHomeAbsent.Name = "calHomeAbsent";
            this.calHomeAbsent.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.calHomeAbsent.Properties.Mask.MaskType = MaskType.None;
            this.calHomeAbsent.Size = new Size(0x95, 20);
            this.calHomeAbsent.StyleController = this.layoutControl1;
            this.calHomeAbsent.TabIndex = 4;
            this.glkPayInsuranceTableList.Location = new Point(0x72, 0x11a);
            this.glkPayInsuranceTableList.Name = "glkPayInsuranceTableList";
            this.glkPayInsuranceTableList.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo), new EditorButton(ButtonPredefines.Glyph, "", -1, true, true, false, ImageLocation.MiddleCenter, (Image) manager.GetObject("glkPayInsuranceTableList.Properties.Buttons"), new KeyShortcut(Keys.None), appearance, "", null, null, true) });
            this.glkPayInsuranceTableList.Properties.NullText = "[Chọn đợt b\x00e1o c\x00e1o để ph\x00e1t sinh]";
            this.glkPayInsuranceTableList.Properties.View = this.gridLookUpEdit1View;
            this.glkPayInsuranceTableList.Size = new Size(0x176, 0x16);
            this.glkPayInsuranceTableList.StyleController = this.layoutControl1;
            this.glkPayInsuranceTableList.TabIndex = 9;
            this.glkPayInsuranceTableList.ButtonClick += new ButtonPressedEventHandler(this.glk_ButtonClick);
            this.gridLookUpEdit1View.Columns.AddRange(new GridColumn[] { this.colPayInsuranceTableListName });
            this.gridLookUpEdit1View.FocusRectStyle = DrawFocusRectStyle.RowFocus;
            this.gridLookUpEdit1View.Name = "gridLookUpEdit1View";
            this.gridLookUpEdit1View.OptionsSelection.EnableAppearanceFocusedCell = false;
            this.gridLookUpEdit1View.OptionsView.ShowGroupPanel = false;
            this.colPayInsuranceTableListName.Caption = "Đợt b\x00e1o c\x00e1o";
            this.colPayInsuranceTableListName.FieldName = "PayInsuranceTableListName";
            this.colPayInsuranceTableListName.Name = "colPayInsuranceTableListName";
            this.colPayInsuranceTableListName.Visible = true;
            this.colPayInsuranceTableListName.VisibleIndex = 0;
            bits = new int[4];
            this.calMoney.EditValue = new decimal(bits);
            this.calMoney.Location = new Point(0x72, 0x75);
            this.calMoney.Name = "calMoney";
            this.calMoney.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.calMoney.Size = new Size(0x176, 20);
            this.calMoney.StyleController = this.layoutControl1;
            this.calMoney.TabIndex = 5;
            this.txtDescription.Location = new Point(0x72, 0xa9);
            this.txtDescription.Name = "txtDescription";
            this.txtDescription.Size = new Size(0x176, 0x5d);
            this.txtDescription.StyleController = this.layoutControl1;
            this.txtDescription.TabIndex = 8;
            bits = new int[4];
            this.calProgressAbsent.EditValue = new decimal(bits);
            this.calProgressAbsent.Location = new Point(0x72, 0x3d);
            this.calProgressAbsent.Name = "calProgressAbsent";
            this.calProgressAbsent.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.calProgressAbsent.Properties.Mask.MaskType = MaskType.None;
            this.calProgressAbsent.Size = new Size(0x176, 20);
            this.calProgressAbsent.StyleController = this.layoutControl1;
            this.calProgressAbsent.TabIndex = 2;
            bits = new int[4];
            this.calPublicAbsent.EditValue = new decimal(bits);
            this.calPublicAbsent.Location = new Point(0x72, 0x59);
            this.calPublicAbsent.Name = "calPublicAbsent";
            this.calPublicAbsent.Properties.Buttons.AddRange(new EditorButton[] { new EditorButton(ButtonPredefines.Combo) });
            this.calPublicAbsent.Properties.Mask.MaskType = MaskType.None;
            this.calPublicAbsent.Size = new Size(0x8f, 20);
            this.calPublicAbsent.StyleController = this.layoutControl1;
            this.calPublicAbsent.TabIndex = 3;
            this.txtTime.Location = new Point(0x72, 0x21);
            this.txtTime.Name = "txtTime";
            this.txtTime.Size = new Size(0x176, 20);
            this.txtTime.StyleController = this.layoutControl1;
            this.txtTime.TabIndex = 1;
            this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
            this.layoutControlGroup1.EnableIndentsWithoutBorders = DefaultBoolean.True;
            this.layoutControlGroup1.GroupBordersVisible = false;
            this.layoutControlGroup1.Items.AddRange(new BaseLayoutItem[] { this.layoutControlItem5, this.layoutControlItem8, this.layoutControlItem9, this.emptySpaceItem1, this.layoutControlItem4, this.layoutControlItem2, this.layoutControlItem6, this.layoutControlItem3, this.layoutControlItem7, this.layoutControlItem1, this.layoutControlItem10 });
            this.layoutControlGroup1.Location = new Point(0, 0);
            this.layoutControlGroup1.Name = "layoutControlGroup1";
            this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5);
            this.layoutControlGroup1.Size = new Size(0x1ef, 0x137);
            this.layoutControlGroup1.Spacing = new DevExpress.XtraLayout.Utils.Padding(0, 0, 0, 0);
            this.layoutControlGroup1.Text = "layoutControlGroup1";
            this.layoutControlGroup1.TextVisible = false;
            this.layoutControlItem5.Control = this.txtDescription;
            this.layoutControlItem5.CustomizationFormText = "layoutControlItem5";
            this.layoutControlItem5.Location = new Point(0, 160);
            this.layoutControlItem5.Name = "layoutControlItem5";
            this.layoutControlItem5.Size = new Size(0x1e5, 0x65);
            this.layoutControlItem5.Spacing = new DevExpress.XtraLayout.Utils.Padding(0, 0, 2, 2);
            this.layoutControlItem5.Text = "Ghi ch\x00fa bổ sung:";
            this.layoutControlItem5.TextSize = new Size(0x67, 13);
            this.layoutControlItem8.Control = this.calMoney;
            this.layoutControlItem8.CustomizationFormText = "Tỷ lệ nộp bổ sung:";
            this.layoutControlItem8.Location = new Point(0, 0x6c);
            this.layoutControlItem8.Name = "layoutControlItem8";
            this.layoutControlItem8.Size = new Size(0x1e5, 0x1c);
            this.layoutControlItem8.Spacing = new DevExpress.XtraLayout.Utils.Padding(0, 0, 2, 2);
            this.layoutControlItem8.Text = "Số tiền:";
            this.layoutControlItem8.TextSize = new Size(0x67, 13);
            this.layoutControlItem9.Control = this.glkPayInsuranceTableList;
            this.layoutControlItem9.CustomizationFormText = "Chọn đợt b\x00e1o c\x00e1o:";
            this.layoutControlItem9.Location = new Point(0, 0x113);
            this.layoutControlItem9.Name = "layoutControlItem9";
            this.layoutControlItem9.Size = new Size(0x1e5, 0x1a);
            this.layoutControlItem9.Text = "Chọn đợt b\x00e1o c\x00e1o:";
            this.layoutControlItem9.TextSize = new Size(0x67, 13);
            this.emptySpaceItem1.CustomizationFormText = "emptySpaceItem1";
            this.emptySpaceItem1.Location = new Point(0, 0x105);
            this.emptySpaceItem1.Name = "emptySpaceItem1";
            this.emptySpaceItem1.Size = new Size(0x1e5, 14);
            this.emptySpaceItem1.Text = "emptySpaceItem1";
            this.emptySpaceItem1.TextSize = new Size(0, 0);
            this.layoutControlItem4.Control = this.calPublicAbsent;
            this.layoutControlItem4.CustomizationFormText = "Nghỉ tại gia đ\x00ecnh:";
            this.layoutControlItem4.Location = new Point(0, 80);
            this.layoutControlItem4.Name = "layoutControlItem4";
            this.layoutControlItem4.Size = new Size(0xfe, 0x1c);
            this.layoutControlItem4.Spacing = new DevExpress.XtraLayout.Utils.Padding(0, 0, 2, 2);
            this.layoutControlItem4.Text = "Nghỉ tại gia đ\x00ecnh:";
            this.layoutControlItem4.TextSize = new Size(0x67, 13);
            this.layoutControlItem2.Control = this.txtTime;
            this.layoutControlItem2.CustomizationFormText = "Tăng từ th\x00e1ng:";
            this.layoutControlItem2.Location = new Point(0, 0x18);
            this.layoutControlItem2.Name = "layoutControlItem2";
            this.layoutControlItem2.Size = new Size(0x1e5, 0x1c);
            this.layoutControlItem2.Spacing = new DevExpress.XtraLayout.Utils.Padding(0, 0, 2, 2);
            this.layoutControlItem2.Text = "Thời gian đ\x00f3ng BHXH:";
            this.layoutControlItem2.TextSize = new Size(0x67, 13);
            this.layoutControlItem6.Control = this.calHomeAbsent;
            this.layoutControlItem6.CustomizationFormText = "Nghỉ tập trung:";
            this.layoutControlItem6.Location = new Point(0xfe, 80);
            this.layoutControlItem6.Name = "layoutControlItem6";
            this.layoutControlItem6.Padding = new DevExpress.XtraLayout.Utils.Padding(2, 2, 4, 4);
            this.layoutControlItem6.Size = new Size(0xe7, 0x1c);
            this.layoutControlItem6.Text = "Nghỉ tập trung:";
            this.layoutControlItem6.TextAlignMode = TextAlignModeItem.AutoSize;
            this.layoutControlItem6.TextSize = new Size(0x49, 13);
            this.layoutControlItem6.TextToControlDistance = 5;
            this.layoutControlItem3.Control = this.calProgressAbsent;
            this.layoutControlItem3.CustomizationFormText = "Lũy kế số ng\x00e0y nghỉ:";
            this.layoutControlItem3.Location = new Point(0, 0x34);
            this.layoutControlItem3.Name = "layoutControlItem3";
            this.layoutControlItem3.Size = new Size(0x1e5, 0x1c);
            this.layoutControlItem3.Spacing = new DevExpress.XtraLayout.Utils.Padding(0, 0, 2, 2);
            this.layoutControlItem3.Text = "Lũy kế số ng\x00e0y nghỉ:";
            this.layoutControlItem3.TextSize = new Size(0x67, 13);
            this.layoutControlItem7.Control = this.cboCondition;
            this.layoutControlItem7.CustomizationFormText = "Loại hưởng:";
            this.layoutControlItem7.Location = new Point(0, 0);
            this.layoutControlItem7.Name = "layoutControlItem7";
            this.layoutControlItem7.Size = new Size(0x1e5, 0x18);
            this.layoutControlItem7.Text = "Điều kiện t\x00ednh hưởng:";
            this.layoutControlItem7.TextSize = new Size(0x67, 13);
            this.layoutControlItem1.Control = this.dtFromDate;
            this.layoutControlItem1.CustomizationFormText = "Nghỉ từ ng\x00e0y:";
            this.layoutControlItem1.Location = new Point(0, 0x88);
            this.layoutControlItem1.Name = "layoutControlItem1";
            this.layoutControlItem1.Size = new Size(0xfe, 0x18);
            this.layoutControlItem1.Text = "Nghỉ từ ng\x00e0y:";
            this.layoutControlItem1.TextSize = new Size(0x67, 13);
            this.layoutControlItem10.Control = this.dtToDate;
            this.layoutControlItem10.CustomizationFormText = "Đến ng\x00e0y:";
            this.layoutControlItem10.Location = new Point(0xfe, 0x88);
            this.layoutControlItem10.Name = "layoutControlItem10";
            this.layoutControlItem10.Size = new Size(0xe7, 0x18);
            this.layoutControlItem10.Text = "Đến ng\x00e0y:";
            this.layoutControlItem10.TextAlignMode = TextAlignModeItem.AutoSize;
            this.layoutControlItem10.TextSize = new Size(0x33, 13);
            this.layoutControlItem10.TextToControlDistance = 5;
            this.btIncrease.Anchor = AnchorStyles.Right | AnchorStyles.Top;
            this.btIncrease.ImageIndex = 2;
            this.btIncrease.ImageList = this.imageCollection1;
            this.btIncrease.Location = new Point(150, 0x146);
            this.btIncrease.Name = "btIncrease";
            this.btIncrease.Size = new Size(0x8b, 0x17);
            this.btIncrease.TabIndex = 0;
            this.btIncrease.Text = "Ph\x00e1t Sinh (>>)";
            this.btIncrease.Click += new EventHandler(this.btIncrease_Click);
            this.imageCollection1.ImageStream = (ImageCollectionStreamer) manager.GetObject("imageCollection1.ImageStream");
            this.imageCollection1.Images.SetKeyName(0, "ico_alpha_Search_16x16.png");
            this.imageCollection1.Images.SetKeyName(1, "ico_alpha_Delete_16x16.png");
            this.imageCollection1.Images.SetKeyName(2, "document2.png");
            this.imageCollection1.Images.SetKeyName(3, "open-16x16.png");
            this.imageCollection1.Images.SetKeyName(4, "direction_next.png");
            this.btClose.Anchor = AnchorStyles.Right | AnchorStyles.Top;
            this.btClose.ImageIndex = 1;
            this.btClose.ImageList = this.imageCollection1;
            this.btClose.Location = new Point(0x193, 0x146);
            this.btClose.Name = "btClose";
            this.btClose.Size = new Size(0x59, 0x17);
            this.btClose.TabIndex = 2;
            this.btClose.Text = "Đ\x00f3ng (X)";
            this.btClose.Click += new EventHandler(this.btClose_Click);
            this.btNext.Anchor = AnchorStyles.Right | AnchorStyles.Top;
            this.btNext.ImageIndex = 4;
            this.btNext.ImageList = this.imageCollection1;
            this.btNext.Location = new Point(0x128, 0x146);
            this.btNext.Name = "btNext";
            this.btNext.Size = new Size(0x65, 0x17);
            this.btNext.TabIndex = 1;
            this.btNext.Text = "Bỏ qua (>>)";
            this.btNext.Click += new EventHandler(this.btNext_Click);
            base.AutoScaleDimensions = new SizeF(6f, 13f);
            base.AutoScaleMode = AutoScaleMode.Font;
            base.ClientSize = new Size(0x1f3, 0x167);
            base.Controls.Add(this.btNext);
            base.Controls.Add(this.btClose);
            base.Controls.Add(this.btIncrease);
            base.Controls.Add(this.groupControl1);
            base.MaximizeBox = false;
            base.MinimizeBox = false;
            base.Name = "xfmC68aHDAdd";
            base.ShowIcon = false;
            base.ShowInTaskbar = false;
            base.StartPosition = FormStartPosition.CenterScreen;
            this.Text = "Đề nghị hưởng chế độ DSPHSK sau ốm đau";
            base.Load += new EventHandler(this.xfmIncrease_Load);
            this.groupControl1.EndInit();
            this.groupControl1.ResumeLayout(false);
            this.layoutControl1.EndInit();
            this.layoutControl1.ResumeLayout(false);
            this.dtToDate.Properties.VistaTimeProperties.EndInit();
            this.dtToDate.Properties.EndInit();
            this.dtFromDate.Properties.VistaTimeProperties.EndInit();
            this.dtFromDate.Properties.EndInit();
            this.cboCondition.Properties.EndInit();
            this.calHomeAbsent.Properties.EndInit();
            this.glkPayInsuranceTableList.Properties.EndInit();
            this.gridLookUpEdit1View.EndInit();
            this.calMoney.Properties.EndInit();
            this.txtDescription.Properties.EndInit();
            this.calProgressAbsent.Properties.EndInit();
            this.calPublicAbsent.Properties.EndInit();
            this.txtTime.Properties.EndInit();
            this.layoutControlGroup1.EndInit();
            this.layoutControlItem5.EndInit();
            this.layoutControlItem8.EndInit();
            this.layoutControlItem9.EndInit();
            this.emptySpaceItem1.EndInit();
            this.layoutControlItem4.EndInit();
            this.layoutControlItem2.EndInit();
            this.layoutControlItem6.EndInit();
            this.layoutControlItem3.EndInit();
            this.layoutControlItem7.EndInit();
            this.layoutControlItem1.EndInit();
            this.layoutControlItem10.EndInit();
            this.imageCollection1.EndInit();
            base.ResumeLayout(false);
        }

        public void RaiseCreatedEventHander()
        {
            if (this.Created != null)
            {
                this.Created(this);
            }
        }

        private void SetValue(int Record)
        {
            this.m_EmployeeCode = this.dt_Employee.Rows[Record]["EmployeeCode"].ToString();
            this.m_EmployeeName = this.dt_Employee.Rows[Record]["FirstName"].ToString() + " " + this.dt_Employee.Rows[Record]["LastName"].ToString();
            this.m_SocialInsuranceCode = this.dt_Employee.Rows[Record]["InsuranceCode"].ToString();
            this.m_Description = this.txtDescription.Text = "";
            this.m_Count--;
            if (this.m_Count < 0)
            {
                this.btNext.Enabled = false;
            }
            string[] strArray = new string[] { "Đề nghị hưởng chế độ DSPHSK sau ốm đau - ", this.m_EmployeeName, " (", this.m_EmployeeCode, ") - ", (this.m_Count + 1).ToString(), " mẫu tin đang đợi" };
            this.Text = string.Concat(strArray);
        }

        private void xfmIncrease_Load(object sender, EventArgs e)
        {
        }

        public delegate void CreatedEventHander(object sender);
    }
}

